﻿using System;
using System.Collections.Generic;
using System.Linq;
using FreeSql.DataAnnotations;
using System.Text;
using System.Threading.Tasks;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel;
using BBCore.Core.Models.EnumTypes;
using System.Security;
using FreeSql;
using System.Diagnostics.CodeAnalysis;

namespace BBCore.Core.Models.Admins
{
    /// <summary>
    /// 按钮权限表
    /// </summary>
    [Table(Name = "HYJ_BUTTONPERMISSION")]
    [Description("按钮权限表")]
    public class ButtonPermission: BaseEntity<ButtonPermission, int>
    {

        //[Column(IsPrimary = true, IsIdentity = true)]
        //public int Id { get; set; }//当没有指明主键时，标记自增的成员将成为主键；
        [Display(Name = "用户名")]
        [Column(IsNullable = false)]
        [Required(ErrorMessage = "用户名不可为空")]
        public string? UserName { get; set; }

        [Display(Name = "菜单URL")]
        [Column(IsNullable = false)]
        [Required(ErrorMessage = "菜单URL不可为空")]
        public string? MenuUrl { get; set; }

        [Display(Name = "按钮权限")]
        public string? Permissions { get; set; }
    }
}
